import ReactDOM from "react-dom/client";

import store from "./store";
import App from "./App";

const root = ReactDOM.createRoot(document.querySelector("#root")!);
root.render(<App />);

// 订阅 store 的变化，并重新 render
store.subscribe(() => {
  root.render(<App />);
});
